/**
 * "Visual Paradigm: DO NOT MODIFY THIS FILE!"
 * 
 * This is an automatic generated file. It will be regenerated every time 
 * you generate persistence class.
 * 
 * Modifying its content may cause the program not work, or your work may lost.
 */

/**
 * Licensee: DuKe TeAm
 * License Type: Purchased
 */
package orm;

import java.util.List;
import org.hibernate.criterion.DetachedCriteria;
import org.orm.PersistentSession;
import org.orm.criteria.*;

public class Trp_provinciaDetachedCriteria extends AbstractORMDetachedCriteria {
	public final IntegerExpression pr_id_prov;
	public final StringExpression pr_des_prov;
	
	public Trp_provinciaDetachedCriteria() {
		super(orm.Trp_provincia.class, orm.Trp_provinciaCriteria.class);
		pr_id_prov = new IntegerExpression("pr_id_prov", this.getDetachedCriteria());
		pr_des_prov = new StringExpression("pr_des_prov", this.getDetachedCriteria());
	}
	
	public Trp_provinciaDetachedCriteria(DetachedCriteria aDetachedCriteria) {
		super(aDetachedCriteria, orm.Trp_provinciaCriteria.class);
		pr_id_prov = new IntegerExpression("pr_id_prov", this.getDetachedCriteria());
		pr_des_prov = new StringExpression("pr_des_prov", this.getDetachedCriteria());
	}
	
	public Trp_regionDetachedCriteria createRegionCriteria() {
		return new Trp_regionDetachedCriteria(createCriteria("region"));
	}
	
	public Trp_colegioDetachedCriteria createTrp_colegioCriteria() {
		return new Trp_colegioDetachedCriteria(createCriteria("ORM_Trp_colegio"));
	}
	
	public Trp_provincia uniqueTrp_provincia(PersistentSession session) {
		return (Trp_provincia) super.createExecutableCriteria(session).uniqueResult();
	}
	
	public Trp_provincia[] listTrp_provincia(PersistentSession session) {
		List list = super.createExecutableCriteria(session).list();
		return (Trp_provincia[]) list.toArray(new Trp_provincia[list.size()]);
	}
}

